PIC calculator

The page stays on your computer. The PIC calculates the answers over USB.

Connect the PIC by USB, then check the connection.

Choose a calculation.

Answers are calculated by the PIC and shown with five decimal places.
How to use this demo

Program the PIC with the external calculator example, connect it by USB, and open this HTML file in your browser. No PC web server or installation is needed. Allow access to local devices if your browser asks.

For your own firmware, select External HTML (data only) in the USB configuration tool. Keep Allowed page origin as null when opening this file directly. Set both Value capacity and Values per response to 4, with output names Sin, Tg, Root, Input in that order. Set Browser input slots to 2.

The PIC's normal home address may show “Not found” in external mode; this is expected. Use this file for the controls. If a request fails, check the USB connection, address, external-page setting and browser permission.

Use one calculator window at a time. Repeating the same number may display the existing matching answer; the four output values do not identify each calculation separately. Five displayed decimal places do not guarantee five accurate decimal places with Float arithmetic.